package com.shkco.feign;

import com.shkco.domain.User;
import com.shkco.result.JSONResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@FeignClient(name = "service-user",fallbackFactory = UserServiceFallbackFactory.class)
public interface UserService {

    @PostMapping("/user/update")
    JSONResult update(@RequestBody User user);

    @GetMapping("/user/findById/{id}")
    User findById(@PathVariable("id") Long id);

}
